package day4.Object;

/**
 * ClassName：TestObject
 *
 * @Author：小鱼
 * @Create：2025-08-07 11:19
 */
public class TestObject {
    public static void main(String[] args) {
        Student s1 =  new Student("张三",20);
        Student s2 =  new Student("张三",20);

        System.out.println(s1==s2);

        System.out.println(s1.equals(s2));

        Object ob = new Object();
        System.out.println(s1.equals(ob));
        System.out.println(s1.equals(s1));

        System.out.println(s1.hashCode());
        System.out.println(s2.hashCode());



    }


}
